/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package parser;

import java.util.ArrayList;

/**
 *
 * @author nate
 */
public class CompositePhrase implements Phrase
{
    private static CompositePhrase instance = null;
    private ArrayList<Phrase> phrase = new ArrayList<Phrase>();


   private CompositePhrase()
   {
      // Exists only to defeat instantiation.
   }

    public type GetType()
    {
        return type.COMPOSITE;
    }

    public void Save(Phrase newPhrase)
    {
        phrase.add(newPhrase);
    }

   public static CompositePhrase getInstance()
   {
      if(instance == null)
      {
         instance = new CompositePhrase();
      }
      return instance;
   }
}


